package com.system.queue.feign;

import com.system.queue.domain.Appointment;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * @className: AppointmentServiceFeign
 * @description: TODO 类描述
 * @author: Kuangkeli
 * @date: 2023/11/30 15:47
 **/
@FeignClient(value = "appointment-service", path = "/appointment")
public interface AppointmentServiceFeign {
    @PostMapping("/save")
    boolean saveAppointment(Appointment appointment);

    @DeleteMapping("/del/{id}")
    boolean removeAppointmentById(@PathVariable("id")int id);

    @PutMapping("/update")
    boolean modifyAppointment(Appointment appointment);

    @GetMapping("/get/{id}")
    Appointment getAppointmentById(@PathVariable("id")int id);

    @GetMapping("/get/list")
    List<Appointment> listAllAppointments();
}
